//
//  AppStartViewController.swift
//  Jock
//
//  Created by HD on 15/3/11.
//  Copyright (c) 2015年 Haidy. All rights reserved.
//

import UIKit

class AppStartViewController: UIViewController {
    
    override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
        super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
    }

    required init(coder aDecoder: NSCoder) {
        super.init(coder: aDecoder)
    }
    
    override func viewDidLoad() {
        super.viewDidLoad()
        self.navigationController?.navigationBarHidden = true
        var sleepTime = 3000
        var launchView = ViewUtil.instanceView("Launch")
        launchView.frame = view.frame
        self.view.addSubview(launchView)
        TimeUtil.sleep(sleepTime, callback: { () -> Void in
            let controller = ViewUtil.instanceViewController("View", identifier: "MainView")
            self.navigationController?.pushViewController(controller, animated: false)
        })
    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
    }

}
